import datetime
import time
import random

def log_decorator(func):
    def wrapper():
        current_time= datetime.datetime.now()
        print(f"Log {current_time}")
        result = func()
        print(f"Result = {result}\n")
    return wrapper

@log_decorator
def random_result():
    return(random.random())

""" @log_decorator
def random_add(a):
    return(random.random()+a) """

if __name__ == "__main__":
    for i in range(10):
        print(i)
        random_result()
        time.sleep(random.random()*5)
